import  request from '@/utils/request'

export function getChatList(query) {
  return request({
    url: '/chat/list',
    method: 'get',
    params: query
  }) 
}

export function chatSend(userId,message,oldMessage) {
  const data = {
    userId: userId,
    message: message,
    oldMessage: oldMessage
  }
  return request({
    url: '/chat/send',
    method: 'post',
    data
  }) 
}